#17.Input: Three names, on separate lines from the keyboard.
#Output: Three Input names in alphabetical order.
 
$index = 0;

print "plese enter the name from keyboard";  
 while ( $name = <> )
 {
 $names[$index++] = uc($name);
 }
 print "the sorted list of names is :\n\n\n";
 foreach $nameinorder (sort @names) 
 {
 print ("$nameinorder");
 }